#include "NuclearMissile.h"

CNuclearMissile::CNuclearMissile(void)
{
}

CNuclearMissile::~CNuclearMissile(void)
{
}
bool CNuclearMissile::collisionCallback(CSceneObject *obj) {
	DEBUG_PRINT("NUCLEAR COLLISION DETECTED\n");

	return false;
}
void CNuclearMissile::passTime(f32) {
	if(!this->getTarget())
		return;

	f32 distance = this->getPosition().getDistanceFrom(this->getTarget()->getPosition());
	
	if(distance < this->getStandoffRange()) {
		if(this->mTarget->getType() == E_GAMEOBJECT_TYPE::Ship) {
			CShip *ptr = (CShip *)this->mTarget;
			//ptr->applyDamage();
		}
		this->misDestroyed = true;
	}
}